<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">

    <!-- CSRF Token -->
    <meta name="csrf-token" content="{{ csrf_token() }}">

    <title>@yield('title', config('app.name')){{ get_setting('site_title')?' - '.get_setting('site_title'):'' }}</title>

    <meta name="description"
          content="@yield('description', get_setting('seo_description', config('app.name').' 爱好者社区。'))"/>
    <meta name="keywords" content="@yield('keyword', get_setting('seo_keyword', config('app.name').',社区,论坛,开发者论坛'))"/>

    <!-- Styles -->
    <link href="{{ mix('css/app.css') }}" rel="stylesheet">

    @yield('styles')
</head>

<body>
<div id="app" class="{{ route_class() }}-page">

    @include('layouts._header')

    <div class="{{ if_route('topics.create') || if_route('topics.edit')?'container-fluid':'container' }}">

        @include('shared._messages')

        @yield('content')

    </div>

    @include('layouts._footer')
</div>

@if (config('app.debug'))
    @include('sudosu::user-selector')
@endif

<!-- Scripts -->
<script src="{{ mix('js/app.js') }}"></script>

@yield('scripts')

</body>

</html>
